<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8">
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<meta name="format-detection" content="telephone=no" />
		<meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
		<script src="../../script/mui.min.js"></script>
		<script src="../../script/jquery.min.js"></script>
		<link rel="stylesheet" href="../../css/mui.min.css" />
		<link rel="stylesheet" type="text/css" href="../../css/weui.min.css">
		<link rel="stylesheet" href="../../css/base.css"/>
		<link rel="stylesheet" href="../../css/exam.css">
		<link rel="stylesheet" href="../../css/swiper-3.4.2.min.css">
		<title>Mocc课程考试页</title>
		<script src="../../script/jquery.min.js" type="text/javascript"></script>
		<script type="text/javascript" charset="utf-8">
			mui.init();
		</script>
		<style>
			.weui_mask {
				position: fixed;
				z-index: 998;
				top: 0;
				right: 0;
				bottom: 0;
				left: 0;
			}
			.weui_dialog {
				z-index: 999;
			}
			.swiper-wrapper {
				min-height: 450px
			}
			.pingfen  label~
			input {
				float: left;
				width: 25%;
				height: 70%;
				padding: 8px 0px;
				margin-bottom: 0;
				padding-left: 0;
				border: 1px solid #d9d9d9;
			}
			.pingfen  label {
				font-family: 'Helvetica Neue', Helvetica, sans-serif;
				line-height: 1.1;
				vertical-align: middle;
				float: left;
				width: 19%;
				padding: 0.7em 0;
				padding-left: 0.8em;
				padding-right: 0.1em
			}
			.pingfen  span {
				font-family: 'Helvetica Neue', Helvetica, sans-serif;
				line-height: 1.1;
				vertical-align: middle;
				float: left;
				width: 55%;
				padding: 0.7em 0.1em;
			}
			.stu-test .mui-btn-primary {
				color: #fff;
				background-color: #FF9900;
				border: 1px solid #FF9900;
				padding-left: 2em;
				padding-right: 2em;
			}
			.questionItemImgDiv {
				height: 12em;
				width: 80%;
				max-height: 14em;
				max-width: 95%;
				margin-left: 13px;
			}
			.xuanzeImgDiv {
				width: 80%;
				height: 8em;
				max-height: 10em;
			}
			.tiankong {
				font-family: inherit;
				border-bottom: 1px solid #000;
				margin: 0 8px;
				text-align: center;
				width: auto;
				/*word-break:break-all*/
			}
			.question_video_div {
				padding: 10px 10px;
				padding-left: 20px;
			}
			.question_video_div	video {
				width: 100%;
				height: 13em;
				background-color: black;
			}
			.question_video_div	img {
				width: 100%;
				height: 10em;
				background-color: black;
			}
			.option_video_div {
				padding: 10px 10px;
				padding-left: 55px;
			}
			.option_video_div	img {
				width: 100%;
				height: 8em;
				background-color: black;
			}
			.option_video_div	video {
				width: 100%;
				height: 12em;
			}
			table {
				border: 1px solid #ccc;
				border-collapse: collapse;
				border-spacing: 0;
			}
			td, th {
				border: 1px solid #ccc;
				padding: 0;
				text-align: center;
				color: #222222;
				font-size: 14px;
			}
		</style>
	</head>
	<body >
		<div class="stu-test" id="scroll">
			<div class="base_style_color" id='BarAppearance' style="height: 22px;width: 100%; position:fixed; left: 0px;top:0px;z-index: 998" ></div>
			<div class="base_navigation_bar base_style_color base_navigation_item_bar" style="position: fixed;left: 0px;top: 20px;">
				<div class="base_navigation_bar base_style_color base_navigation_item_bar">
					<a class="base_left_item" href="#" onclick="backTestToast()"> <img class="base_back_icon" src="../../image/icon_jiantou.png" alt=""> </a>
					<span id="title"></span>
				</div>
			</div>
			<div class="ReviewWeekly_div  " style="margin-top: 64px"></div>
			<div class="space10"></div>
			<div class="k-con-border qusetion-type" >
				<div class="k-con-part" style="position: static">
					<p class="k-text-center k-c323 k-f12">
						<span class="test-score-detail "> 试卷分数：<span class="k-cred" id="score"></span>分 </span>
						<span class="test-score-detail"> 通过分数：<span class="k-cred" id="passscore"></span>分 </span>
						<span class="test-score-detail"> 考试时间：<span class="k-cred" id="kstime"></span>分 </span>
					</p>
				</div>
			</div>
			<div class="k-con test-m-bottom70 test-analysis" id="question_div">
				<div class="swiper-container">
					<div class="swiper-wrapper" >
						<!--	<div class="swiper-slide" id="item' + (i + 1) + '" itemtype="' + data.qtype + '" qid="' + data.qid + '">
						<div class="k-con-part3 clearfix">
						<span id="itemType" class="k-f18">填空题</span>
						<p class="k-f16 k-c323 k-mt5 indent-5">
						<span> 1.
						11111111111111111111111111111111111111111111111111111111111111
						<input class="tiankong" id="test319253" onkeypress="demo(319253)"  data-qid="319253" name="319253[]">
						"11111111111111111111111111111111111111111111111111111111111111"
						<input class="tiankong" id="test319254" onkeypress="demo(319254)"  data-qid="319253" name="319253[]">
						11111111111111111111111111111111111111111111111111111111111111
						<input class="tiankong" id="test319255" onkeypress="demo(319255)"  data-qid="319253" name="319253[]">
						</span>
						</p>
						<div class="test-answer-list left_10"  id="question_item' + data.qid + '"  onclick="GetAnswerData(' + i + ')"></div>
						</div>
						</div>-->
					</div>
				</div>
			</div>
			<div class="k-con1 k-text-center k-fixed-bottom test-bottom1" id="sub_div">
				<div class="k-con-part1" id='sub_bt' style="display: none;">
					<div class="remainingtime ">
						<span> 倒计时 </span>
						<span id="kaoShiTime" class="k-cred"></span>
					</div>
					<button type="button" class="mui-btn mui-btn-primary" onclick="CheckSubmit()">
						交卷
					</button>
					<div class="test_card_div">
						<a class="base_right_item "style="color: #18B4ED" href="#popover-card">答题卡 </a>
					</div>
				</div>
				<div class="k-con-part" id='score_bt' style="display: none;">
					<span class="test-score-detail"> 你的分数：<span class="k-cred" id="your_score" ></span>分 </span>
					<div class="test_card_div" style="top: -10px">
						<a class="base_right_item "style="color: #18B4ED" href="#popover-card">答题卡 </a>
					</div>
				</div>
			</div>
			<div id="popover-card" class="mui-popover test-num-card" style=" width: 97%">
				<div class="mui-scroll-wrapper">
					<div class="mui-scroll" id="scroll-card"></div>
				</div>
			</div>
		</div>
		<div id="offlineAlert" class="weui_dialog_confirm" style="display: none;">
			<div class="weui_mask"></div>
			<div class="weui_dialog">
				<div class="weui_dialog_hd">
					<strong class="weui_dialog_title" id="checkNum"></strong>
				</div>
				<div class="weui_dialog_bd"></div>
				<div class="weui_dialog_ft">
					<a onclick="cleanCancel()" href="#" class="weui_btn_dialog default"  style="color:#18b4ed">取消</a>
					<a onclick="cleanConfirm()" href="#" class="weui_btn_dialog primary"  style="color:#18b4ed">确定</a>
				</div>
			</div>
		</div>
		<div class="weui_dialog_alert" id="closeAlert" style="display: none;">
			<div class="weui_mask"></div>
			<div class="weui_dialog">
				<div class="weui_dialog_hd">
					<strong class="weui_dialog_title" id="checkNum2"></strong>
				</div>
				<div class="weui_dialog_ft">
					<a onclick="Cancel()" href="#" class="weui_btn_dialog primary"  style="color:#18b4ed">确定</a>
				</div>
			</div>
		</div>
		<div id="LookAlert" class="weui_dialog_confirm" style="display: none;">
			<div class="weui_mask"></div>
			<div class="weui_dialog">
				<div class="weui_dialog_hd">
					<strong class="weui_dialog_title" id="tilte_look"></strong>
				</div>
				<div class="weui_dialog_bd"></div>
				<div class="weui_dialog_ft">
					<a onclick="lookno()" href="#" class="weui_btn_dialog default">取消</a>
					<a onclick="lookyes()" href="#" class="weui_btn_dialog primary"  style="color:#18b4ed">确定</a>
				</div>
			</div>
		</div>
		<div id="AgainTestAlert" class="weui_dialog_confirm" style="display: none;">
			<div class="weui_mask"></div>
			<div class="weui_dialog">
				<div class="weui_dialog_hd">
					<strong class="weui_dialog_title" id="tilte_AgainTest"></strong>
				</div>
				<div class="weui_dialog_bd"></div>
				<div class="weui_dialog_ft">
					<a onclick="AgainTest_no()" href="#" class="weui_btn_dialog default">取消</a>
					<a onclick="AgainTest_yes()" href="#" class="weui_btn_dialog primary"  style="color:#18b4ed">确定</a>
				</div>
			</div>
		</div>
	</body>
	<script type="text/javascript" src="../../script/api.js"></script>
	<script src="../../script/jquery.min.js" type="text/javascript"></script>
	<script type="text/javascript" src="../../script/MD5.js"></script>
	<script src="../../script/common.js"></script>
	<script src="../../script/swiper-3.4.2.jquery.min.js" type="text/javascript"></script>
	<script type="text/javascript" src="../../script/requestTool.js"></script>
	<script type="text/javascript" src="../../script/courseTest.js"></script>
	<script type="text/javascript" src="../../script/attachmentManager.js"></script>
	<script type="text/javascript">
		var daan = new Object();
		var questionLen = '';
		/*题目名称数组*/
		var itemNameArr = new Array();
		/*题目id数组*/
		var qidArr = new Array();
		/*点击状态，0不正常，1正常,3异常,5,重考页面，6.提交空卷成功后*/
		var clickNum = "";
		/*计划id*/
		var pid = "";
		/*课程id*/
		var cid = "";
		/*章节id*/
		var chapterid = "";
		/*试卷id*/
		var tid = "";
		/*考试开始时间*/
		var stime = "";
		/*考试时长*/
		var timeNum = "";
		/*考试通过成绩*/
		var passScore = "";
		/*考试通过成绩*/
		var isanswer = "";
		/*考试次数*/
		var examnum = "";
		/*考试密钥*/
		var token = "";
		/*最多考核次数*/
		var e_big_exam = "";
		/*考核是否显示成绩*/
		var e_display_cj = "";
		/*考核是否显示答案*/
		var e_display_da = "";
		/*考核成绩*/
		var userscore = "";
		/*考核状态 1考核题目加载成功，3考核题目加载失败*/
		var kstype = "";
		/*考核结果id*/
		var testid = "";
		/*考核名称*/
		var course_name;
		var apiready = function() {
			//开启加载框
			showProgress();
			scrollUI();
			//获取数据
			preData();
			// 滚动监听
			SubBtnlisten();
			//按钮返回提示
			kebackListen();
		}
		function sendBuriedNotifi(busionessid, pagetype, pagetypeid) {
			var userinfo = {
				uid : $api.getStorage('cfnetppuid'),
				jid : $api.getStorage('cfnetppjxid'),
				uname : $api.getStorage('cfnetppusername'),
				cid : api.pageParam.courseid,
				pid : api.pageParam.planid,
				exam_id : api.pageParam.exam_id,
			}
			var data = {
				busionessid : busionessid,
				pagetype : pagetype,
				pagetypeid : pagetypeid,
				sourceurl : api.pageParam.sourceurl,
				sourcetitle : api.pageParam.sourcetitle,
				accesspageurl : window.location.pathname,
				accesspagetitle : document.title,
				userinfo : userinfo
			}
			SendBehaviorTrajectoriesNotifi_Study(data);
		}

		//页面预加载数据
		function preData() {
			var pageParam = api.pageParam;
			var h = api.winHeight * 0.3;
			$('#popover-card').css('height', h);
			if (api.pageParam.open_type != 1) {//开始考试状态
				startExam();
			} else {
				clickNum = 5
				getExamInfo();
				loadTestExamScoreData();
			}
		}

		//获取token值
		function startExam() {
			if (api.pageParam.exam_id == "") {
				hideProgress();
				back('当前章节数据为空');
				return false;
			}
			var param = {
				appkey : api.pageParam.appkey,
				match_type : api.pageParam.match_type,
				user_id : $api.getStorage('cfnetppuid'),
				exam_id : api.pageParam.exam_id,
				plan_id : api.pageParam.plan_id,
			};
			cfnetppPOST(url_getCourseExamToken, param, false, function(data, status) {
				if (status == 'success') {
					if (data.code == 200) {
						var list = data.data;
						if (list != null && list != '') {
							token = list.token;
							stime = list.timestamp;
							getExamInfo();
							loadTestExamData();
						} else {
							back('当前考试数据为空');
							clickNum = 3;
						}
					} else if (data.code == 128) {
						back('当前章节数据为空');
						clickNum = 3;
					} else {
						back('数据异常');
						clickNum = 3;
					}
				} else {
					api.toast({
						msg : '网络异常',
						duration : 2000,
						location : 'bottom'
					});
				}
			});
		}

		//获取课程考试基本信息
		function getExamInfo() {
			var param = {
				exam_id : api.pageParam.exam_id,
			};
			cfnetppPOST(url_getCourseExamInfo, param, false, function(data, status) {
				if (status == 'success') {
					if (data.code == 200) {
						var list = data.data;
						if (list != null && list != '') {
							$('#score').text(list.zscore);
							passScore = parseInt(list.efen);
							$('#passscore').text(passScore);
							$('#kstime').text(list.dtime);
							course_name = list.ename;
							$('#title').text(list.ename);
							timeNum = parseInt(list.dtime) * 60;
							e_big_exam = parseInt(list.e_big_exam);
							//考核完是否显示成绩
							e_display_cj = parseInt(list.e_display_cj);
							//是否显示答案
							e_display_da = parseInt(list.e_display_da);
						} else {
							back('当前章节数据为空');
							clickNum = 3;
						}
					} else if (data.code == 128 || data.code == 108) {
						back('当前章节数据为空');
						clickNum = 3;
					} else {
						back('数据异常');
						clickNum = 3;
					}
				} else {
					api.toast({
						msg : '网络异常',
						duration : 2000,
						location : 'bottom'
					});
				}
			});
		}

		//考试题目接口
		function loadTestExamData() {
			var param = {
				exam_id : api.pageParam.exam_id,
				token : token,
				user_id : $api.getStorage('cfnetppuid'),
			};
			cfnetppPOST(url_getCourseExamQuestions, param, false, function(data, status) {
				hideProgress();
				if (status == 'success') {
					if (data.code == 200) {
						var list = JSON.parse(data.data);
						if (list != null) {
							kstype = 1;
							var examList = GetHtmlTestArrayList(list);
							questionLen = examList.length;
							setUpObject(examList);
							$(".swiper-wrapper").append(SetTestExamUI(examList));
							//初始化swiper
							InitmySwiper();
							//显示提交按钮
							$('#sub_bt').show();
							//计时器
							daojishi();
						} else {
							back('考试题目为空');
							clickNum = 3;
						}
					} else if (data.code == 116) {
						back('考试次数达到上限');
						clickNum = 3;
					} else if (data.code == 111) {
						back('已过期');
						clickNum = 3;
					} else if (data.code == 110) {
						back('未开始');
						clickNum = 3;
					} else if (data.code == 108) {
						back('考试题目为空');
						clickNum = 3;
					} else {
						back('数据异常');
						clickNum = 3;
					}
				} else {
					api.toast({
						msg : '网络异常',
						duration : 2000,
						location : 'bottom'
					});
				}
			});
		}

		//考试题目结果接口
		function loadTestExamScoreData() {
			var param = {
				exam_id : api.pageParam.exam_id,
				sid : api.pageParam.score_id,
				user_id : $api.getStorage('cfnetppuid'),
			};
			cfnetppPOST(url_getCourseExamjiuguo, param, false, function(data, status) {
				hideProgress();
				if (status == 'success') {
					if (data.code == 200) {
						var list = data.data;
						if (list != null) {
							var examList = GetHtmlTestArrayList(list);
							if (examList != '') {
								$('#sub_bt').hide();
								if (e_display_cj == 1) {//显示成绩
									$('#score_bt').show();
									$('#your_score').text(api.pageParam.score);
								} else {//不显示成绩
									$('#score_bt').hide();
								}
								SetCourseExamScoreUI(examList);
							} else {
								back('考试题目为空');
								clickNum = 3;
							}
						} else {
							back('考试题目为空');
							clickNum = 3;
						}
					} else if (data.code == 116) {
						back('考试次数达到上限');
						clickNum = 3;
					} else if (data.code == 111) {
						back('已过期');
						clickNum = 3;
					} else if (data.code == 110) {
						back('未开始');
						clickNum = 3;
					} else {
						back('数据异常');
						clickNum = 3;
					}
				} else {
					api.toast({
						msg : '网络异常',
						duration : 2000,
						location : 'bottom'
					});
				}
			});
		}

		//检查题目是否提交
		function CheckSubmit() {
			DeleteAnswerNullData();
			var daanLen = ObjectCount(daan);
			var strLen = questionLen - daanLen;
			if (strLen > 0) {//题目未答数量大于0
				$("#checkNum").text("您还有" + strLen + "道题未提交,是否确定提交?");
			} else {
				$("#checkNum").text("是否确定提交？");
			}
			$('#offlineAlert').show();
			clickNum = 1;
		}

		//退出考试提示
		function backTestToast() {
			if (clickNum == 3) {
				closeWindow();
			} else if (clickNum == 5) {
				closeWindow();
			} else {
				if (kstype == 1) {
					$("#checkNum").html("是否确定退出考试页面？<br/>考试只有一次机会，一旦退出计作0分");
				} else {
					$("#checkNum").text("是否确定退出考试?");
				}
				$('#offlineAlert').show();
				clickNum = 2;
			}
		}

		//退出考试提示
		function back(str) {
			$('#sub_bt').hide();
			$("#checkNum2").text(str);
			$('#closeAlert').show();
		}

		function Cancel() {
			$('#closeAlert').hide();
			closeWindow();
		}

		function cleanCancel() {
			$('#offlineAlert').hide();
		}

		function closeWindow() {
			sendBuriedNotifi('1', '学生端课程考核页', '074');
			if (api.pageParam.type == 1) {//自由课程章节列表跳转过来
				if (api.pageParam.hasOwnProperty('openType') && api.pageParam.openType == "train_stu") {//实习学习跳转而来
					api.closeToWin({
						name : 'Student_trainFreeCourseTab'
					});
				} else {//教学学习跳转而来
					api.closeToWin({
						name : 'Student_FreeCourseTab'
					});
				}
			} else if (api.pageParam.type == 3) {//消息列表跳转过来
				api.closeWin({
				});
			} else {
				api.closeWin({
				});
			}
		}

		//确定
		function cleanConfirm() {
			$('#offlineAlert').hide();
			if (clickNum == 1) {
				showProgress();
				SubmitData();
			} else if (clickNum == 2) {
				if (kstype == 1) {
					daan = "{}";
					clickNum = 6;
					SubmitData();
					closeWindow();
				} else {
					closeWindow();
				}
			} else if (clickNum == 5) {
				closeWindow();
			}
		}

		//提交答题数据
		function SubmitData() {
			var etime = (Date.parse(new Date())) / 1000;
			var param = {
				appkey : api.pageParam.appkey,
				token : token,
				match_type : 3,
				exam_id : api.pageParam.exam_id,
				stime : stime,
				etime : etime,
				sub_type : 1,
				plan_id : api.pageParam.plan_id,
				user_id : $api.getStorage('cfnetppuid'),
				jid : $api.getStorage('cfnetppjxid'),
				course_id : api.pageParam.course_id,
				user_answer : daan,
				message : course_name
			};
			cfnetppPOST(url_CourseExamSubmit, param, false, function(data, status) {
				hideProgress();
				SendBusinessOperationsLogNotifi('学生端课程考核页', '074', param, param, '', data, '学生端课程考核提交接口', '074-01')
				if (status == 'success') {
					if (data.code == 200) {
						var list = data.data;
						if (list != null) {
							testid = list.id.score_id;
							sendNotifi();
							var testInfo = "";
							if (e_display_cj == 1) {//显示成绩
								testInfo = "当前得分" + list.fenshu + "分";
							} else {
								testInfo = "";
							}
							if (clickNum == 6) {//提交空卷成功后,直接退出不再进行成绩判断
								closeWindow();
							} else {
								userscore = list.fenshu;
								if (e_display_cj == 1) {//显示成绩
									if (list.is_pass == 1) {//考试通过
										$('#LookAlert').show();
										$("#tilte_look").text(testInfo + ",恭喜您已通过考试！是否查看详情？");
									} else if (list.is_pass == 0) {//考试未通过
										if (e_big_exam == 0) {//考试总次数为无数次
											$('#AgainTestAlert').show();
											$("#tilte_AgainTest").text(testInfo + ",很遗憾未通过考试,是否重考？");
										} else {//考试未通过但考试次数未达到上限
											if (e_big_exam == list.count) {
												//												back(testInfo + ",很遗憾未通过考试,考试次数已达到上限");
												$('#closeAlert').show();
												$("#checkNum2").text(testInfo + ",很遗憾未通过考试,考试次数已达到上限");
											} else {
												$('#AgainTestAlert').show();
												$("#tilte_AgainTest").text(testInfo + ",很遗憾未通过考试，您还有" + (e_big_exam - list.count) + "次考试机会,是否重考？");
											}
										}
									}
								} else if (e_display_cj == 0 || e_display_cj == null) {//不显示成绩
									if (list.is_pass == 1) {//考试通过
										$('#closeAlert').show();
										$("#checkNum2").text(testInfo + ",恭喜您已通过考试！");
									} else if (list.is_pass == 0) {//考试未通过
										if (e_big_exam == 0) {//考试未通过但考试次数已到上限
											//											back('您的成绩暂未通过,考试次数已达到上限');
											$('#AgainTestAlert').show();
											$("#tilte_AgainTest").text(testInfo + ",很遗憾未通过考试,是否重考？");
										} else {
											if (e_big_exam == list.count) {
												//												back('您的成绩暂未通过,考试次数已达到上限');
												$('#closeAlert').show();
												$("#checkNum2").text("您的成绩暂未通过,考试次数已达到上限");
											} else {
												$('#AgainTestAlert').show();
												$("#tilte_AgainTest").text("很遗憾未通过考试，您还有" + (e_big_exam - list.count) + "次考试机会,是否重考？");
											}
										}
									}
								} else {
									back('请等待阅卷');
								}
							}
						} else {
							back('考试题目为空');
							clickNum = 3;
						}
					} else if (data.code == 116) {
						back('考试次数达到上限');
						clickNum = 3;
					} else if (data.code == 111) {
						back('已过期');
						clickNum = 3;
					} else if (data.code == 110) {
						back('未开始');
						clickNum = 3;
					} else {
						back('数据异常');
						clickNum = 3;
					}
				} else {
					api.toast({
						msg : '提交失败',
						duration : 2000,
						location : 'bottom'
					});
				}
			});
		}

		function AgainTest_no() {
			$('#AgainTestAlert').hide();
			api.closeWin({
			});
		}

		function AgainTest_yes() {
			$('#AgainTestAlert').hide();
			AgainTest();
		}

		function lookyes() {
			$('#LookAlert').hide();
			openTestScore();
		}

		function lookno() {
			$('#LookAlert').hide();
			api.closeWin({
			});
		}

		//重考
		function AgainTest() {
			var y = 0;
			var h = api.winHeight - y;
			api.openWin({useWKWebView:true,
				name : 'Student_CourseTestExam',
				url : 'Student_CourseTestExam.html',
				rect : {
					x : 0,
					y : y,
					w : 'auto',
					h : h,
				},
				pageParam : {
					appkey : api.pageParam.appkey,
					match_type : api.pageParam.match_type,
					exam_id : api.pageParam.exam_id,
					plan_id : api.pageParam.plan_id,
					course_id : api.pageParam.course_id,
					openType : api.pageParam.openType
				},
				reload : true
			});
		}

		//打开课程考核详情页
		function openTestScore() {
			var y = 0;
			var h = api.winHeight - y;
			api.openWin({useWKWebView:true,
				name : 'Student_CourseTestExam',
				url : 'Student_CourseTestExam.html',
				rect : {
					x : 0,
					y : y,
					w : 'auto',
					h : h,
				},
				pageParam : {
					appkey : api.pageParam.appkey,
					match_type : api.pageParam.match_type,
					exam_id : api.pageParam.exam_id,
					course_id : api.pageParam.course_id,
					score_id : testid,
					open_type : 1,
					type : 0,
					score : userscore,
					openType : api.pageParam.openType
				},
				reload : true
			});
		}

		function sendNotifi() {
			api.sendEvent({
				name : 'RefreshCourseTestNotifi'
			});
		}
	</script>
</html>